#ifndef MYTCPSERVER_H
#define MYTCPSERVER_H

#include <QTcpServer>

class MyTcpServer : public QTcpServer
{
    Q_OBJECT
public:
    explicit MyTcpServer(QObject *parent = nullptr);
protected slots:
    void socketDisconnectedSlot();
    void threadFinishedSlot();

protected:
    void incomingConnection(qintptr socketDescriptor);
signals:
    void sendControlMessage(const QJsonObject &obj);
    void deviceControlToOne(QString index,const  QByteArray &data);
    void sendUserChat(QString from,QString name,QString to,QString msg);
    void sendGroupChat(int groupId,QString groupname,QString userName,QString msg);
    void updateGroupList(int userId);
public slots:
};

#endif // MYTCPSERVER_H
























